From a65dc12392c2dc3d00486686f846209411c95b3e Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 19 Oct 2023 21:43:35 -0400 Subject: [PATCH] gsk: Use vertex arrays when we can Use the new has_vertex_arrays api to determine whether we can use vertex arrays in GL.` Fixes: #6173 --- gsk/gl/gskglcommandqueue.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gsk/gl/gskglcommandqueue.c b/gsk/gl/gskglcommandqueue.c index 0924b73993..8a6ad31fd7 100644 --- a/gsk/gl/gskglcommandqueue.c +++ b/gsk/gl/gskglcommandqueue.c @@ -1070,7 +1070,7 @@ gsk_gl_command_queue_execute (GskGLCommandQueue *self, glBlendFunc (GL_ONE, GL_ONE_MINUS_SRC_ALPHA); glBlendEquation (GL_FUNC_ADD); - if (!gdk_gl_context_get_use_es (self->context)) + if (gdk_gl_context_has_vertex_arrays (self->context)) { glGenVertexArrays (1, &vao_id); glBindVertexArray (vao_id); @@ -1257,7 +1257,7 @@ gsk_gl_command_queue_execute (GskGLCommandQueue *self, } glDeleteBuffers (1, &vbo_id); - if (!gdk_gl_context_get_use_es (self->context)) + if (gdk_gl_context_has_vertex_arrays (self->context)) glDeleteVertexArrays (1, &vao_id); gdk_profiler_set_int_counter (self->metrics.n_binds, n_binds); -- 2.30.2